/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package controllers;

import java.io.IOException;
import java.net.Inet4Address;
import util.PartDownload;
import util.IncompleteFile;
import util.RemoteFile;

/**
 *
 * @author Victor
 */
public class DownloadsController {
    
    DatabaseController dbController;
    public static int LISTENING_PORT = 5557;
    
    public DownloadsController(DatabaseController dbController){
        this.dbController = dbController;
    }

    
    public IncompleteFile createDownload(RemoteFile downloadFile) throws IOException {
        IncompleteFile download = new IncompleteFile(downloadFile, this.dbController);
        //CRIA NOVA THREAD, E COLOCA O DOWNLOAD PARA RODAR
        
        return download;
    }
  
}
